window.onload = function () {
    function changeState() {
        let shuzi = document.getElementsByClassName("number")[0].innerHTML;

        shuzi++;
        document.getElementsByClassName("number")[0].innerHTML = shuzi;
        let a = setTimeout(changeState, 20);

        if (document.getElementsByClassName("number")[0].innerHTML >= 138) {
            clearTimeout(a);
        }
    }

    function changeState3() {
        let shuzi = document.getElementsByClassName("number")[1].innerHTML;

        shuzi++;
        document.getElementsByClassName("number")[1].innerHTML = shuzi;
        let a = setTimeout(changeState3, 20);

        if (document.getElementsByClassName("number")[1].innerHTML >= 97) {
            clearTimeout(a);
        }
    }

    function changeState1() {
        let shuzi = document.getElementsByClassName("number")[2].innerHTML;

        shuzi++;
        document.getElementsByClassName("number")[2].innerHTML = shuzi;
        let a = setTimeout(changeState1, 20);

        if (document.getElementsByClassName("number")[2].innerHTML >= 1) {
            clearTimeout(a);
        }
    }
    function changeState2() {
        let shuzi = document.getElementsByClassName("number")[3].innerHTML;

        shuzi++;
        document.getElementsByClassName("number")[3].innerHTML = shuzi;
        let a = setTimeout(changeState2, 1);

        if (document.getElementsByClassName("number")[3].innerHTML >= 576) {
            clearTimeout(a);
        }
    }
    changeState()
    changeState2()
    changeState1()
    changeState3()
}
